﻿using System.ComponentModel.DataAnnotations;
using System.ComponentModel.DataAnnotations.Schema;

namespace IS_Ever_Green.DataAccess.Model
{
    public class ProductModel
    {
        [Key]
        public int ProductId { get; set; }

        public int CategoryId { get; set; }

        public int ManufacturerId { get; set; }

        [Required]
        public string Name { get; set; }

        public decimal Price { get; set; }

        public string Description { get; set; }

        public int AvailableQuantity { get; set; }

        public byte[] PhotoProduct { get; set; }

        [NotMapped]
        public string PhotoPath { get; set; }

        public CategoryModel Category { get; set; }
        public ManufacturerModel Manufacturer { get; set; }
        public ICollection<OrderItemModel> OrderItems { get; set; }
        public ICollection<ReviewModel> Reviews { get; set; }
        public ICollection<CartModel> Carts { get; set; }
    }
}
